package com.yangcangclub.mq.base;

import com.yangcangclub.commons.config.SysConfig;
import org.mybatis.spring.SqlSessionTemplate;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.redis.core.RedisTemplate;

/**
 * 领域对象基类
 */
public abstract class MQBaseDomain {
    @Autowired
    public SysConfig sysConfig;
    @Autowired
    public RedisTemplate<Object,Object> redisTemplate;

    @Autowired
    private SqlSessionTemplate masterSqlSessionTemplate;
    @Autowired
    private SqlSessionTemplate slaveSqlSessionTemplate;

    public SqlSessionTemplate getMasterJdbc(){
        return this.masterSqlSessionTemplate;
    }
    public SqlSessionTemplate getSlaveJdbc(){
        return this.slaveSqlSessionTemplate;
    }


}